home *** CD-ROM | disk | FTP | other *** search
- "
- #
- # This is a set of regression tests for the boundedNum objects.
- #
- # boundedNum.tests.self,v 1.1 1993/05/14 22:44:03 richards Exp
- #
- # boundedNum.tests.self,v
- * Revision 1.1 1993/05/14 22:44:03 richards
- * Initial revision
- *
- #
- #
- "
-
- _AddSlotsIfAbsent: (| bnumTests. |)
- bnumTests _AddSlotsIfAbsent: (| foo. bar. |)
-
- bnumTests foo: aa bnum copy value: 10
- ('Test 1: ', ((bnumTests foo printString) = 'Bnum<-Inf|Inf>: 10') printString) printLine
- ('Test 2: ', ((bnumTests foo lower: 40) printString = 'Bnum<40|Inf>: 10') printString) printLine
- ('Test 3: ', ((bnumTests foo upper: 100) printString = 'Bnum<40|100>: 10') printString) printLine
- ('Test 4: ', ((bnumTests foo value: 10) printString = 'Bnum<40|100>: 40') printString) printLine
- ('Test 5: ', ((bnumTests foo value: 1000) printString = 'Bnum<40|100>: 100') printString) printLine
- (bnumTests bar: bnumTests foo - 100)
- ('Test 6: ', ((bnumTests bar) printString = 'Bnum<40|100>: 40') printString) printLine
- (bnumTests foo: bnumTests foo * 0.5)
- ('Test 7: ', ((bnumTests foo) printString = 'Bnum<40|100>: 50.0') printString) printLine
- (bnumTests foo: bnumTests foo * 0.5)
- ('Test 8: ', ((bnumTests foo) printString = 'Bnum<40|100>: 40') printString) printLine
- _RemoveSlot: 'bnumTests'
-
-